
#ifndef __SEMAPHORE_H__
#define __SEMAPHORE_H__

#include "atomic.h"
#include "libs/queue.h"
#include "kernel/task/task.h"
#include "libs/types.h"



class Semaphore
{
private:
    /* data */
public:
    atomic_t count;
    Queue<task> waitList;
    Semaphore(/* args */uint64_t);
    ~Semaphore();
    void __down();
    void down();
    void __up();
    void up();
};






#endif